from fastapi import APIRouter, Depends, status

from app.api.deps import (
    CurrentUser,
    SessionDep,

)


from app import  models
from app import services


router = APIRouter()


@router.get("/university")
async def get_university_by_name(session: SessionDep, current_user: CurrentUser,name:str) -> models.UniversitysPublic:
    """
    根据名称返回大学
    """
           
    return await services.UsersService(current_user=current_user,db=session).get_university_by_name(name)

